package com.fuxinglianbao.services;

import com.fuxinglianbao.models.PaymentOrder;
import com.fuxinglianbao.models.WithdrawRecord;
import java.math.BigDecimal;

public interface PaymentService {
    /**
     * 创建支付订单
     */
    PaymentOrder createPaymentOrder(Long userId, BigDecimal amount, PaymentOrder.PaymentType paymentType, String notifyUrl, String returnUrl);

    /**
     * 处理支付回调
     */
    void handlePaymentNotify(String orderNo, String transactionId, PaymentOrder.PaymentStatus status);

    /**
     * 查询支付订单
     */
    PaymentOrder getPaymentOrder(String orderNo);

    /**
     * 创建提现申请
     */
    WithdrawRecord createWithdrawRequest(Long userId, BigDecimal amount, WithdrawRecord.WithdrawType withdrawType,
                                       String accountInfo);

    /**
     * 审核提现申请
     */
    void processWithdrawRequest(String withdrawNo, WithdrawRecord.WithdrawStatus status, String remark);

    /**
     * 查询提现记录
     */
    WithdrawRecord getWithdrawRecord(String withdrawNo);
}